<template>
  <div class="iconFull" @click="selectFolder">
    <el-icon>
      <Folder />
    </el-icon>
  </div>
</template>

<script setup>
import { ipcApiRoute } from "@/api/main.js"
import { ipc } from "@/utils/ipcRenderer.js"

const emits = defineEmits(['selected'])

const selectFolder = () => {
  ipc.invoke(ipcApiRoute.selectFolder, '').then(r => {
    console.log(r)
    emits('selected', r)
  })
}

</script>

<style lang="scss" scoped>
.iconFull {
  width: 100%;
  height: 100%;
  cursor: pointer;
  padding: 0px 10px;
}
</style>